package com.cai.servlet.common.user.log;


import com.cai.dao.UserTopicDao;
import com.cai.dao.impl.UserTopicDaoImpl;

import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

/**
 * @author RuoLi
 * 获取用户帮助提示
 */
@WebServlet(name = "ServletHelpUserLog", value = "/common/log/HelpUserLog")
public class ServletHelpUserLog extends HttpServlet {
    @Override
    protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
        req.setCharacterEncoding("utf-8");
        resp.setContentType("text/html;charset=utf-8");
        UserTopicDao dao = new UserTopicDaoImpl();
        String data = dao.getUserHelpLog();
        resp.getWriter().write(data);
    }

    @Override
    protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
        super.doPost(req, resp);
    }
}
